package gui

import (
	"fyne.io/fyne/v2"
	"fyne.io/fyne/v2/widget"
)

type TreeLabel struct {
	widget.Label
	Path string
}

func NewTreeLabel(text string, path string) *TreeLabel {
	treeLabel := &TreeLabel{}
	treeLabel.ExtendBaseWidget(treeLabel)
	treeLabel.Path = path
	treeLabel.SetText(text)
	return treeLabel
}

// TappedSecondary func (m *externWiget) TappedSecondary(e *fyne.PointEvent) {}//右键点击
func (tl *TreeLabel) TappedSecondary(e *fyne.PointEvent) {
	showContextMenu(tl, e, w)
}
